Total Complexity | 2 |
Total Lines | 13 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | import { Inject, Injectable } from '@nestjs/common'; |
||
6 | |||
7 | @Injectable() |
||
8 | export class AppService { |
||
9 | constructor( |
||
10 | @Inject(TRANSPORT_EVENT_BUS_SERVICE) private readonly eventBus: IEventBus |
||
11 | ){ |
||
12 | |||
13 | } |
||
14 | handleDefaultEvent(): void { |
||
15 | this.eventBus.publish(new DefaultEvent('Pass some param')); |
||
16 | } |
||
17 | rabbitEvent(): void { |
||
18 | this.eventBus.publish(new RabbitEvent('Pass some param')); |
||
19 | } |
||
21 |